ScreenActionDispatch = {
    callbackFuncs = {}
}
local function buildKey(screenId, controlId)
    return screenId .. "_" .. controlId
end
function ScreenActionDispatch:register(screenId, controlId, callback)
    local key = buildKey(screenId, controlId)
    println2("register :", key)
    ScreenActionDispatch.callbackFuncs[key] = callback
    println("ScreenActionDispatch:regitster")
    print_table(ScreenActionDispatch.callbackFuncs)
end

function ScreenActionDispatch:dispatch(screen, control, value, params)
    println("dispatch :", screen, control, value, params)
    if screen ~= nil and control ~= nil then
        local key = buildKey(screen, control)
        println2("key :", key)
        println("ScreenActionDispatch:dispatch")
        print_table(ScreenActionDispatch.callbackFuncs)
        local callback = ScreenActionDispatch.callbackFuncs[key]
        println2("callback :", callback)
        if callback ~= nil then
            callback(value, params)
        end
    end
end

